---
title: 'Build Custom Pieces'
icon: 'box'
---

You can use the CLI to build custom pieces for the platform. This process compiles the pieces and exports them as a `.tgz` packed archive.

### How It Works

The CLI scans the `packages/pieces/` directory for the specified piece. It checks the **name** in the `package.json` file. If the piece is found, it builds and packages it into a `.tgz` archive.

### Usage

To build a piece, follow these steps:

1. Ensure you have the CLI installed by cloning the repository.
2. Run the following command, replacing `PIECE_NAME` with the name of the piece you want to build:

```bash
npm run pieces -- build --name=google-sheets
```
